package com.zhb.feign;

import com.zhb.entity.Account;
import com.zhb.responvo.ResponseInfo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.math.BigDecimal;

/**
 * @Description:
 * @Author: zhb
 * @CreateTime: 2021/9/10
 * @Company: 众调
 */

@FeignClient(name = "account-service")
public interface AccountFeign {

    @RequestMapping("account/getByUserId")
    ResponseInfo<Account> getByUserId();

    @RequestMapping("account/reduce")
    ResponseInfo<Account> reduce(@RequestParam("accountCode") String accountCode,@RequestParam("amount") BigDecimal amount);
}
